{{#if hasLegacySnapshotSettings}}
  <section class="mt-20 mb-20">
    <BannerMessage
      @color="bg-warning m-0"
      @message={{t "clusterNew.rke.etcd.backupConfig.legacy" duration=legacyRetention}}
    />
  </section>
{{/if}}

<section class="header mt-20 clearfix">
  <div class="pull-left">
    <h2 class="mb-0">
      {{t "clusterNew.rke.customize.label"}}
    </h2>
  </div>
  <div class="right-buttons">
    {{#if (and (lte step 1) (not applyClusterTemplate))}}
      {{#if pasteOrUpload}}
        <button {{action "cancel"}} type="button" class="btn btn-sm bg-primary" disabled={{not canEditForm}}>
          {{#if notView}}
            {{t "clusterNew.advanced.cancel"}}
          {{else}}
            {{t "clusterNew.advanced.viewCancel"}}
          {{/if}}
        </button>
      {{else}}
        <button class="btn btn-sm bg-primary" type="button" {{action "showPaste"}}>
          {{#if notView}}
            {{t "clusterNew.advanced.yaml"}} <span class="icon icon-copy"></span>
          {{else}}
            {{t "clusterNew.advanced.viewYaml"}} <span class="icon icon-copy"></span>
          {{/if}}
        </button>
      {{/if}}
    {{/if}}
  </div>
</section>

{{#if (and (not clusterTemplateCreate) notView) }}
  {{#if (or (and isEdit (not isPostSave)) (eq step 1))}}
    <section class="cluster-template-select mb-5">
      <div class="row">
        {{#if (or (or model.clusterTemplateRevisions model.clusterTemplateRevision) clusterTemplatesEnforced)}}
          <div>
            <label class="acc-label" for="use-existing-cluster-template">
              {{input
                class="input-lg"
                type="checkbox"
                checked=useClusterTemplate
                id="use-existing-cluster-template"
                disabled=(or isEdit (or clusterTemplatesEnforced pasteOrUpload))
              }}
              {{t "clusterNew.rke.clustersSelectTemplate.label"}}
            </label>
          </div>
          {{#if useClusterTemplate}}
            <div class="col span-6">
              {{#if filteredClusterTemplates}}
                {{new-select
                  id="input-cluster-template-select"
                  classNames="form-control"
                  optionValuePath="id"
                  optionLabelPath="name"
                  content=filteredClusterTemplates
                  value=selectedClusterTemplateId
                  prompt="clusterNew.rke.clustersSelectTemplate.select.prompt"
                  localizedPrompt=true
                  disabled=isEdit
                }}
              {{else}}
                {{selectedClusterTemplateId}}
              {{/if}}
            </div>
            <div class="col span-6">
              {{#if filteredClusterTemplates}}
                {{new-select
                  classNames="form-control"
                  optionValuePath="id"
                  optionLabelPath="name"
                  content=filteredTemplateRevisions
                  value=clusterTemplateRevisionId
                  disabled=(not selectedClusterTemplateId)
                  prompt="clusterNew.rke.clustersSelectTemplateRevision.select.prompt"
                  localizedPrompt=true
                }}
              {{else}}
                {{clusterTemplateRevisionId}}
              {{/if}}
            </div>
          {{/if}}
        {{/if}}
      </div>
    </section>
  {{/if}}
{{/if}}

{{#if (or clusterTemplateCreate (or (not clusterTemplatesEnforced) (and clusterTemplatesEnforced clusterTemplateRevisionId)))}}
  {{#if (or (and isEdit (not isPostSave)) (eq step 1))}}
    {{#accordion-list
       expandAll=(mut forceExpandAll)
       showExpandAll=true
       as |al expandFn|
    }}
      {{#if pasteOrUpload}}
        {{!-- EDIT YAML  --}}
        <div class="accordion">
          <div class="accordion-header">
            <div class="expand"></div>
            <div class="title">
              <span class="m-0">{{t "clusterNew.kubernetesOptions.title" }}</span>
              <p class="help-block">{{t "clusterNew.kubernetesOptions.detail" }}</p>
            </div>
          </div>
          <div class="accordion-content">
            {{top-errors errors=clusterOptErrors}}

            {{input-yaml
              showCopy=true
              showDownload=false
              canChangeName=false
              autoResize=true
              value=yamlValue
              fileChosen=(action "fileUploaded")
              readOnly=(eq mode "view")
              showUpload=(not-eq mode "view")
              valueUpdated=(action "yamlValUpdated")
            }}
          </div>
        </div>
      {{else}}
        {{!-- EDIT FORM  --}}
        {{#accordion-list-item
           title=(t "clusterNew.kubernetesOptions.title")
           detail=(t "clusterNew.kubernetesOptions.detail")
           expandOnInit=true
           expandAll=al.expandAll
           expand=(action expandFn)
        }}
          <div class="row">
            <div class="col span-6">
              <label class="acc-label">
                {{t "clusterNew.rke.version.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="rancherKubernetesEngineConfig.kubernetesVersion"
                    @configVariable={{config.kubernetesVersion}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>

              <CheckOverrideAllowed
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @paramName="rancherKubernetesEngineConfig.kubernetesVersion"
                @questions={{model.clusterTemplateRevision.questions}}
                @mode={{mode}}
              >
                <FormVersions
                  @applyClusterTemplate={{applyClusterTemplate}}
                  @cluster={{cluster}}
                  @clusterTemplateCreate={{clusterTemplateCreate}}
                  @mode={{mode}}
                  @initialVersion={{initialVersion}}
                  @value={{config.kubernetesVersion}}
                  @versions={{versionChoices}}
                  @clusterTemplateQuestions={{clusterTemplateQuestions}}
                  @showNotAllowed=true
                />
              </CheckOverrideAllowed>
              {{#if showUpgradeK8sWarning}}
                <p class="help-block">
                  {{t "formVersions.helpBlock.label" htmlSafe=true}}
                </p>
              {{/if}}
            </div>
          </div>

          <FormNetworkConfig
            @config={{config}}
            @mode={{mode}}
            @isEditCluster={{isEditCluster}}
            @isCustom={{isCustom}}
            @cluster={{cluster}}
            @enableNetworkPolicy={{primaryResource.enableNetworkPolicy}}
            @clusterTemplateCreate={{clusterTemplateCreate}}
            @clusterTemplateRevision={{model.clusterTemplateRevision}}
            @applyClusterTemplate={{applyClusterTemplate}}
            @addOverride={{action "addOverride"}}
          />

          <div class="row">
            <div class="col span-12">
              <CruCloudProvider
                @cluster={{cluster}}
                @driver={{nodeWhich}}
                @setCpFields={{action "setCpFields"}}
                @mode={{mode}}
                @clusterTemplateCreate={{clusterTemplateCreate}}
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision}}
                @questions={{model.clusterTemplateRevision.questions}}
                @addOverride={{action "addOverride"}}
              />
            </div>
          </div>
        {{/accordion-list-item}}

        {{#accordion-list-item
           title=(t "cruPrivateRegistry.title.label")
           detail=(t "cruPrivateRegistry.title.detail")
           expandOnInit=(or (or (eq mode "edit" true false) forceExpandOnInit) applyClusterTemplate)
           expandAll=al.expandAll
           expand=(action expandFn)
        }}
          <CruPrivateRegistry
            @mode={{mode}}
            @cluster={{cluster}}
            @addRegistry={{action "addRegistry"}}
            @removeRegistry={{action "removeRegistry"}}
            @addOverride={{action "addOverride"}}
            @clusterTemplateCreate={{clusterTemplateCreate}}
            @clusterTemplateRevision={{model.clusterTemplateRevision}}
            @applyClusterTemplate={{applyClusterTemplate}}
          />
        {{/accordion-list-item}}

        {{#accordion-list-item
           title=(t "clusterNew.rke.advanced.label")
           detail=(t "clusterNew.rke.advanced.detail")
           expandOnInit=(or (or (eq mode "edit" true false) forceExpandOnInit) applyClusterTemplate)
           expandAll=al.expandAll
           expand=(action expandFn)
        }}
          <div class="row">
            <div class="col span-3">
              <label class="acc-label">
                {{t "clusterNew.rke.ingress.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="rancherKubernetesEngineConfig.ingress.provider"
                    @configVariable={{config.ingress.provider}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @applyClusterTemplate={{applyClusterTemplate}}
                @paramName="rancherKubernetesEngineConfig.ingress.provider"
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
              >
                {{#input-or-display
                   editable=notView
                   value=config.ingress.provider
                }}
                  <div class="radio">
                    <label>
                      {{radio-button
                        selection=config.ingress.provider
                        value="nginx"
                      }}
                      {{t "generic.enabled"}}
                    </label>
                  </div>
                  <div class="radio">
                    <label>
                      {{radio-button
                        selection=config.ingress.provider
                        value="none"
                      }}
                      {{t "generic.disabled"}}
                    </label>
                  </div>
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>
            <div class="col span-3">
              <label class="acc-label">
                {{t "clusterNew.rke.ingress.defaultBackend.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="rancherKubernetesEngineConfig.ingress.defaultBackend"
                    @configVariable={{config.ingress.defaultBackend}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @applyClusterTemplate={{applyClusterTemplate}}
                @paramName="rancherKubernetesEngineConfig.ingress.defaultBackend"
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
              >
                {{#input-or-display
                   editable=notView
                   value=config.ingress.defaultBackend
                }}
                  <div class="radio">
                    <label>
                      {{radio-button
                        selection=config.ingress.defaultBackend
                        value=true
                      }}
                      {{t "generic.enabled"}}
                    </label>
                  </div>
                  <div class="radio">
                    <label>
                      {{radio-button
                        selection=config.ingress.defaultBackend
                        value=false
                      }}
                      {{t "generic.disabled"}}
                    </label>
                  </div>
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>
            <div class="col span-3">
              <label class="acc-label">
                {{t "clusterNew.rke.serviceNodePortRange.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="rancherKubernetesEngineConfig.services.kubeApi.serviceNodePortRange"
                    @configVariable={{config.services.kubeApi.serviceNodePortRange}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="rancherKubernetesEngineConfig.services.kubeApi.serviceNodePortRange"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
              >
                {{#input-or-display
                   editable=notView
                   value=config.services.kubeApi.serviceNodePortRange
                }}
                  {{input
                    type="text"
                    value=config.services.kubeApi.serviceNodePortRange
                    className="form-control"
                    placeholder=(t "clusterNew.rke.serviceNodePortRange.placeholder")
                  }}
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>
            <div class="col span-3">
              <label class="acc-label">
                {{t "clusterNew.rke.monitoring.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="rancherKubernetesEngineConfig.monitoring.provider"
                    @configVariable={{config.monitoring.provider}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="rancherKubernetesEngineConfig.monitoring.provider"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
              >
                {{#input-or-display
                   editable=notView
                   value=config.monitoring.provider
                }}
                  <div class="radio">
                    <label>
                      {{radio-button
                        selection=config.monitoring.provider
                        value="metrics-server"
                      }}
                      {{t "generic.enabled"}}
                    </label>
                  </div>
                  <div class="radio">
                    <label>
                      {{radio-button
                        selection=config.monitoring.provider
                        value="none"
                      }}
                      {{t "generic.disabled"}}
                    </label>
                  </div>
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>
          </div>
          <div class="row">
            <div class="col span-4">
              <label class="acc-label">
                {{t "clusterNew.rke.podSecurityPolicy.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="rancherKubernetesEngineConfig.services.kubeApi.podSecurityPolicy"
                    @configVariable={{config.services.kubeApi.podSecurityPolicy}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="rancherKubernetesEngineConfig.services.kubeApi.podSecurityPolicy"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
              >
                {{#input-or-display
                   editable=notView
                   value=config.services.kubeApi.podSecurityPolicy
                }}
                  <div class="radio">
                    <label class={{unless model.psps.length "text-muted"}}>
                      {{radio-button
                        selection=config.services.kubeApi.podSecurityPolicy
                        value=true
                        disabled=(not model.psps.length)
                      }}
                      {{t "generic.enabled"}}
                      {{#unless model.psps.length}}
                        &mdash; {{t "clusterNew.psp.none"}}
                      {{/unless}}
                    </label>
                  </div>
                  <div class="radio">
                    <label>
                      {{radio-button
                        selection=config.services.kubeApi.podSecurityPolicy
                        value=false
                        disabled=(not model.psps.length)
                      }}
                      {{t "generic.disabled"}}
                    </label>
                  </div>
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>
            <div class="col span-4">
              {{#if config.services.kubeApi.podSecurityPolicy}}
                <label class="acc-label">
                  {{t "clusterNew.psp.label"}}{{field-required}}
                  {{#if clusterTemplateCreate}}
                    <ClusterTemplateOverrideToggle
                      @path="defaultPodSecurityPolicyTemplateId"
                      @configVariable={{cluster.defaultPodSecurityPolicyTemplateId}}
                      @addOverride={{action "addOverride"}}
                      @questions={{model.clusterTemplateRevision.questions}}
                    />
                  {{/if}}
                </label>
                <CheckOverrideAllowed
                  @paramName="defaultPodSecurityPolicyTemplateId"
                  @applyClusterTemplate={{applyClusterTemplate}}
                  @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                  @questions={{model.clusterTemplateRevision.questions}}
                >
                  {{#input-or-display
                     editable=notView
                     value=cluster.defaultPodSecurityPolicyTemplateId
                  }}
                    {{new-select
                      content=model.psps
                      optionLabelPath="displayName"
                      optionValuePath="id"
                      prompt="clusterNew.psp.prompt"
                      localizedPrompt=true
                      value=cluster.defaultPodSecurityPolicyTemplateId
                      disabled=(not config.services.kubeApi.podSecurityPolicy)
                    }}
                  {{/input-or-display}}
                </CheckOverrideAllowed>
              {{else}}
                <label class="acc-label">
                  {{t "clusterNew.psp.label"}}
                </label>
                <div class="form-control-static">{{t "generic.none"}}</div>
              {{/if}}
            </div>
          </div>
          <div class="row">
            <div class="col span-4">
              <label class="acc-label">
                {{t "clusterNew.rke.ignoreDockerVersion.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="rancherKubernetesEngineConfig.ignoreDockerVersion"
                    @configVariable={{cluster.ignoreDockerVersion}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="rancherKubernetesEngineConfig.ignoreDockerVersion"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
              >
                {{#input-or-display
                   editable=notView
                   value=config.ignoreDockerVersion
                }}
                  <div class="radio">
                    <label>
                      {{radio-button
                        selection=config.ignoreDockerVersion
                        value=false
                      }}
                      {{t "clusterNew.rke.ignoreDockerVersion.disabled"}}
                    </label>
                  </div>
                  <div class="radio">
                    <label>
                      {{radio-button
                        selection=config.ignoreDockerVersion
                        value=true
                      }}
                      {{t "clusterNew.rke.ignoreDockerVersion.enabled"}}
                    </label>
                  </div>
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>

            <div class="col span-4">
              <label class="acc-label">
                {{t "loggingPage.dockerRootDir.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="dockerRootDir"
                    @configVariable={{cluster.dockerRootDir}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="dockerRootDir"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
              >
                {{#input-or-display
                   editable=notView
                   value=cluster.dockerRootDir
                }}
                  {{input
                    type="text"
                    value=cluster.dockerRootDir
                    className="form-control"
                    placeholder=(t "clusterNew.rke.dockerRootDir.placeholder" dir=defaultDockerRootDir)
                  }}
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>

          </div>
          <div class="row">
            <div class="col span-12">
              <label class="acc-label">
                {{t "clusterNew.rke.secretsEncryption.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="rancherKubernetesEngineConfig.services.kubeApi.secretsEncryptionConfig.enabled"
                    @configVariable={{config.services.kubeApi.secretsEncryptionConfig.enabled}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="rancherKubernetesEngineConfig.services.kubeApi.secretsEncryptionConfig.enabled"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
              >
                {{#input-or-display
                   editable=notView
                   value=config.services.kubeApi.secretsEncryptionConfig.enabled
                }}
                  <div>
                    <label class="radio mt-0">
                      {{radio-button selection=config.services.kubeApi.secretsEncryptionConfig.enabled value=true}}
                      {{t "generic.enabled"}}
                    </label>
                  </div>
                  <div>
                    <label class="radio">
                      {{radio-button selection=config.services.kubeApi.secretsEncryptionConfig.enabled value=false}}
                      {{t "generic.disabled"}}
                    </label>
                  </div>
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>
          </div>
          <div class="row">
            <div class="col span-12">
              <label class="acc-label">
                {{t "clusterNew.rke.etcd.location.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="uiOverrideBackupStrategy"
                    @configVariable={{backupStrategy}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="uiOverrideBackupStrategy"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
              >
                {{#input-or-display
                   editable=notView
                   value=backupStrategy
                }}
                  <div>
                    <label class="radio mt-0">
                      {{radio-button selection=backupStrategy value="local"}}
                      {{t "clusterNew.rke.etcd.location.local.label"}}
                      <p class="help-block">
                        {{t "clusterNew.rke.etcd.location.local.help"}}
                      </p>
                    </label>
                  </div>
                  <div>
                    <label class="radio">
                      {{radio-button selection=backupStrategy value="s3"}}
                      {{t "clusterNew.rke.etcd.location.s3.label"}}
                      <p class="help-block">
                        {{t "clusterNew.rke.etcd.location.s3.help"}}
                      </p>
                    </label>
                  </div>
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>
          </div>

          {{#unless (eq backupStrategy "local")}}
            <div class="row">
              <div class="col span-3">
                <label class="acc-label">
                  {{t "clusterNew.rke.etcd.backupConfig.bucketName.label"}}
                  {{#if clusterTemplateCreate}}
                    <ClusterTemplateOverrideToggle
                      @path="rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.bucketName"
                      @configVariable={{config.services.etcd.backupConfig.s3BackupConfig.bucketName}}
                      @addOverride={{action "addOverride"}}
                      @questions={{model.clusterTemplateRevision.questions}}
                    />
                  {{/if}}
                </label>
                <CheckOverrideAllowed
                  @paramName="rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.bucketName"
                  @applyClusterTemplate={{applyClusterTemplate}}
                  @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                  @questions={{model.clusterTemplateRevision.questions}}
                >
                  {{#input-or-display
                     editable=notView
                     value=config.services.etcd.backupConfig.s3BackupConfig.bucketName
                  }}
                    {{input
                      type="text"
                      value=config.services.etcd.backupConfig.s3BackupConfig.bucketName
                      classNames="form-control"
                      placeholder=(t "clusterNew.rke.etcd.backupConfig.bucketName.placeholder")
                    }}
                  {{/input-or-display}}
                </CheckOverrideAllowed>
              </div>

              <div class="col span-3 offset-1">
                <label class="acc-label">
                  {{t "clusterNew.rke.etcd.backupConfig.region.label"}}
                  {{#if clusterTemplateCreate}}
                    <ClusterTemplateOverrideToggle
                      @path="rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.region"
                      @configVariable={{config.services.etcd.backupConfig.s3BackupConfig.region}}
                      @addOverride={{action "addOverride"}}
                      @questions={{model.clusterTemplateRevision.questions}}
                    />
                  {{/if}}
                </label>
                <CheckOverrideAllowed
                  @paramName="rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.region"
                  @applyClusterTemplate={{applyClusterTemplate}}
                  @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                  @questions={{model.clusterTemplateRevision.questions}}
                >
                  {{#input-or-display
                     editable=notView
                     value=config.services.etcd.backupConfig.s3BackupConfig.region
                  }}
                    {{input
                      type="text"
                      value=config.services.etcd.backupConfig.s3BackupConfig.region
                      classNames="form-control"
                      placeholder=(t "clusterNew.rke.etcd.backupConfig.region.placeholder")
                    }}
                  {{/input-or-display}}
                </CheckOverrideAllowed>
              </div>

              <div class="col span-3 offset-1">
                <label class="acc-label">
                  {{t "clusterNew.rke.etcd.backupConfig.endpoint.label"}}
                  {{#if clusterTemplateCreate}}
                    <ClusterTemplateOverrideToggle
                      @path="rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.endpoint"
                      @configVariable={{config.services.etcd.backupConfig.s3BackupConfig.endpoint}}
                      @addOverride={{action "addOverride"}}
                      @questions={{model.clusterTemplateRevision.questions}}
                    />
                  {{/if}}
                </label>
                <CheckOverrideAllowed
                  @paramName="rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.endpoint"
                  @applyClusterTemplate={{applyClusterTemplate}}
                  @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                  @questions={{model.clusterTemplateRevision.questions}}
                >
                  {{#input-or-display
                     editable=notView
                     value=config.services.etcd.backupConfig.s3BackupConfig.endpoint
                  }}
                    {{input
                      type="text"
                      value=config.services.etcd.backupConfig.s3BackupConfig.endpoint
                      classNames="form-control"
                      placeholder=(t "clusterNew.rke.etcd.backupConfig.endpoint.placeholder")
                    }}
                  {{/input-or-display}}
                </CheckOverrideAllowed>
              </div>
            </div>

            <div class="row">
              <div class="col span-3">
                <label class="acc-label">
                  {{t "clusterNew.rke.etcd.backupConfig.folder.label"}}
                  {{#if clusterTemplateCreate}}
                    <ClusterTemplateOverrideToggle
                      @path="rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.folder"
                      @configVariable={{config.services.etcd.backupConfig.s3BackupConfig.folder}}
                      @addOverride={{action "addOverride"}}
                      @questions={{model.clusterTemplateRevision.questions}}
                    />
                  {{/if}}
                </label>
                <CheckOverrideAllowed
                  @paramName="rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.folder"
                  @applyClusterTemplate={{applyClusterTemplate}}
                  @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                  @questions={{model.clusterTemplateRevision.questions}}
                >
                  {{#input-or-display
                     editable=notView
                     value=config.services.etcd.backupConfig.s3BackupConfig.folder
                  }}
                    {{input
                      type="text"
                      name="folder"
                      classNames="form-control"
                      placeholder=(t "clusterNew.rke.etcd.backupConfig.folder.placeholder")
                      value=config.services.etcd.backupConfig.s3BackupConfig.folder
                    }}
                  {{/input-or-display}}
                </CheckOverrideAllowed>
              </div>

              <div class="col span-3 offset-1">
                <label class="acc-label">
                  {{t "clusterNew.rke.etcd.backupConfig.accessKey.label"}}
                  {{#if clusterTemplateCreate}}
                    <ClusterTemplateOverrideToggle
                      @path="rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.accessKey"
                      @configVariable={{config.services.etcd.backupConfig.s3BackupConfig.accessKey}}
                      @addOverride={{action "addOverride"}}
                      @questions={{model.clusterTemplateRevision.questions}}
                    />
                  {{/if}}
                </label>
                <CheckOverrideAllowed
                  @paramName="rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.accessKey"
                  @applyClusterTemplate={{applyClusterTemplate}}
                  @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                  @questions={{model.clusterTemplateRevision.questions}}
                >
                  {{#input-or-display
                     editable=notView
                     value=config.services.etcd.backupConfig.s3BackupConfig.accessKey
                  }}
                    {{input
                      type="text"
                      name="accessKey"
                      classNames="form-control"
                      placeholder=(t "clusterNew.rke.etcd.backupConfig.accessKey.placeholder")
                      value=config.services.etcd.backupConfig.s3BackupConfig.accessKey
                    }}
                  {{/input-or-display}}
                </CheckOverrideAllowed>
              </div>

              <div class="col span-3 offset-1">
                <label class="acc-label">
                  {{t "clusterNew.rke.etcd.backupConfig.secretKey.label"}}
                  {{#if clusterTemplateCreate}}
                    <ClusterTemplateOverrideToggle
                      @path="rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.secretKey"
                      @configVariable={{config.services.etcd.backupConfig.s3BackupConfig.secretKey}}
                      @addOverride={{action "addOverride"}}
                      @questions={{model.clusterTemplateRevision.questions}}
                    />
                  {{/if}}
                </label>
                <CheckOverrideAllowed
                  @paramName="rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.secretKey"
                  @applyClusterTemplate={{applyClusterTemplate}}
                  @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                  @questions={{model.clusterTemplateRevision.questions}}
                >
                  {{#input-or-display
                     editable=notView
                     obfuscate=true
                     value=config.services.etcd.backupConfig.s3BackupConfig.secretKey
                  }}
                    {{input
                      type="password"
                      name="password"
                      classNames="form-control"
                      placeholder=(t "clusterNew.rke.etcd.backupConfig.secretKey.placeholder")
                      value=config.services.etcd.backupConfig.s3BackupConfig.secretKey
                    }}
                  {{/input-or-display}}
                </CheckOverrideAllowed>
              </div>
            </div>
            <div class="row">
              <div class="col span-7">
                <label class="acc-label" for="s3-config-custom-ca">
                  {{#if clusterTemplateCreate}}
                    <ClusterTemplateOverrideToggle
                      @path="rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.customCa"
                      @configVariable={{config.services.etcd.backupConfig.s3BackupConfig.customCa}}
                      @addOverride={{action "addOverride"}}
                      @questions={{model.clusterTemplateRevision.questions}}
                    />
                  {{/if}}
                  {{t "clusterNew.rke.etcd.backupConfig.customCa.label"}}
                </label>
                <CheckOverrideAllowed
                  @paramName="rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.customCa"
                  @applyClusterTemplate={{applyClusterTemplate}}
                  @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                  @questions={{model.clusterTemplateRevision.questions}}
                >
                  {{#input-or-display
                     editable=notView
                     obfuscate=true
                     value=cluster.rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.customCa
                     classesForDisplay="col span-12 force-wrap"
                  }}
                    {{input-text-file
                      accept="application/x-x509-ca-cert,text/plain,.pem,.crt"
                      canChangeName=false
                      classNames="box"
                      id="s3-config-custom-ca"
                      minHeight=60
                      multiple=true
                      placeholder="clusterNew.rke.etcd.backupConfig.customCa.placeholder"
                      shouldChangeName=false
                      value=cluster.rancherKubernetesEngineConfig.services.etcd.backupConfig.s3BackupConfig.customCa
                    }}
                  {{/input-or-display}}
                </CheckOverrideAllowed>
              </div>
            </div>
          {{/unless}}

          <div class="row">
            <div class="col span-3">
              <label class="acc-label">
                {{t "clusterNew.rke.etcd.enabled.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="rancherKubernetesEngineConfig.services.etcd.backupConfig.enabled"
                    @configVariable={{config.services.etcd.backupConfig.enabled}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="rancherKubernetesEngineConfig.services.etcd.backupConfig.enabled"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
              >
                {{#input-or-display
                   editable=notView
                   value=config.services.etcd.backupConfig.enabled
                }}
                  <div class="text-muted">
                    <label>
                      {{radio-button
                        selection=config.services.etcd.backupConfig.enabled
                        value=true
                      }}
                      {{t "generic.yes"}}
                    </label>
                    <label>
                      {{radio-button
                        selection=config.services.etcd.backupConfig.enabled
                        value=false
                      }}
                      {{t "generic.no"}}
                    </label>
                  </div>
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>

            <div class="col span-3 offset-1">
              <label class="acc-label">
                {{t "clusterNew.rke.etcd.backupConfig.interval.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="rancherKubernetesEngineConfig.services.etcd.backupConfig.intervalHours"
                    @configVariable={{config.services.etcd.backupConfig.intervalHours}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="rancherKubernetesEngineConfig.services.etcd.backupConfig.intervalHours"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
              >
                {{#input-or-display
                   tagName="div"
                   classNames="input-group"
                   editable=notView
                   value=(concat config.services.etcd.backupConfig.intervalHours (concat " " (t "generic.hours")))
                }}
                  {{input-integer
                    value=config.services.etcd.backupConfig.intervalHours
                    min=1
                    classNames="form-control"
                    placeholder=(t "clusterNew.rke.etcd.backupConfig.interval.placeholder")
                    disabled=(unless config.services.etcd.backupConfig.enabled true)
                  }}
                  <span class="input-group-addon bg-default">{{t "generic.hours"}}</span>
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>

            <div class="col span-3 offset-1">
              <label class="acc-label">
                {{t "clusterNew.rke.etcd.backupConfig.retention.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="rancherKubernetesEngineConfig.services.etcd.backupConfig.retention"
                    @configVariable={{config.services.etcd.backupConfig.retention}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="rancherKubernetesEngineConfig.services.etcd.backupConfig.retention"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
              >
                {{#input-or-display
                   tagName="div"
                   classNames="input-group"
                   editable=notView
                   value=config.services.etcd.backupConfig.retention
                }}
                  <span class="input-group-addon bg-default">{{t "clusterNew.rke.etcd.backupConfig.retention.prefix"}}</span>
                  {{input-integer
                    value=config.services.etcd.backupConfig.retention
                    min=1
                    classNames="form-control"
                    placeholder=(t "clusterNew.rke.etcd.backupConfig.retention.placeholder")
                    disabled=(unless config.services.etcd.backupConfig.enabled true)
                  }}
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>
          </div>

          <div class="row" id="security-scan">
            <div class="col span-3">
              <label class="acc-label">
                {{t "clusterNew.rke.cisScan.scheduled.enabled.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="scheduledClusterScan.enabled"
                    @configVariable={{config.services.etcd.backupConfig.enabled}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="scheduledClusterScan.enabled"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
              >
                {{#input-or-display
                   editable=notView
                   value=scheduledClusterScan.enabled
                }}
                  <div>
                    <label class="text-muted">
                      {{radio-button
                        selection=scheduledClusterScan.enabled
                        value=true
                        disabled=isScheduledClusterScanDisabled
                      }}
                      {{t "generic.yes"}}
                    </label>
                    <label class="text-muted">
                      {{radio-button
                        selection=scheduledClusterScan.enabled
                        value=false
                        disabled=isScheduledClusterScanDisabled
                      }}
                      {{t "generic.no"}}
                    </label>
                  </div>
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>

            <div class="col span-3">
              <label class="acc-label">
                {{t "clusterNew.rke.cisScan.scheduled.profile.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="cisProfile"
                    @configVariable={{cisProfile}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="cisProfile"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
                @value={{cisProfileDisplay}}
              >
                {{#input-or-display
                   tagName="div"
                   editable=notView
                   value=cisProfileDisplay
                }}
                  {{new-select
                    id="cis-scan-profile"
                    classNames="form-control"
                    content=cisScanProfileOptions
                    value=cisProfile
                    disabled=(not scheduledClusterScan.enabled)
                  }}
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>

            <div class="col span-3">
              <label class="acc-label">
                {{t "clusterNew.rke.cisScan.scheduled.interval.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="scheduledClusterScan.scheduleConfig.cronSchedule"
                    @configVariable={{scheduledClusterScan.scheduleConfig.cronSchedule}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="scheduledClusterScan.scheduleConfig.cronSchedule"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
                @value={{scheduledClusterScan.scheduleConfig.cronSchedule}}
              >
                {{#if notView}}
                  {{input
                    type="text"
                    value=scheduledClusterScan.scheduleConfig.cronSchedule
                    classNames="form-control"
                    placeholder=(t "clusterNew.rke.cisScan.scheduled.interval.placeholder")
                    disabled=(not scheduledClusterScan.enabled)
                  }}
                {{else}}
                  <div>{{scheduledClusterScan.scheduleConfig.cronSchedule}}</div>
                {{/if}}
                <div class="text-small text-muted">{{pretty-cron scheduledClusterScan.scheduleConfig.cronSchedule "toString"}}</div>

              </CheckOverrideAllowed>
            </div>

            <div class="col span-3">
              <label class="acc-label">
                {{t "clusterNew.rke.cisScan.scheduled.retention.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="scheduledClusterScan.scheduleConfig.retention"
                    @configVariable={{scheduledClusterScan.scheduleConfig.retention}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="scheduledClusterScan.scheduleConfig.retention"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
                @value={{scheduledClusterScan.scheduleConfig.retention}}
              >
                {{#input-or-display
                   tagName="div"
                   editable=notView
                   classNames="input-group"
                   value=scheduledClusterScan.scheduleConfig.retention
                }}
                  <span class="input-group-addon bg-default">{{t "clusterNew.rke.etcd.backupConfig.retention.prefix"}}</span>
                  {{input-integer
                    value=scheduledClusterScan.scheduleConfig.retention
                    classNames="form-control"
                    placeholder=(t "clusterNew.rke.etcd.backupConfig.retention.placeholder")
                    disabled=(not scheduledClusterScan.enabled)
                  }}
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>
          </div>

          <div class="row">
            <div class="col">
              <label class="acc-label">
                {{t "clusterNew.rke.upgradeStrategy.maximumWorkersDown.label"}}
                {{#if clusterTemplateCreate}}
                  <ClusterTemplateOverrideToggle
                    @path="upgradeStrategy.maxUnavailableWorker"
                    @configVariable={{upgradeStrategy.maxUnavailableWorker}}
                    @addOverride={{action "addOverride"}}
                    @questions={{model.clusterTemplateRevision.questions}}
                  />
                {{/if}}
              </label>
              <CheckOverrideAllowed
                @paramName="upgradeStrategy.maxUnavailableWorker"
                @applyClusterTemplate={{applyClusterTemplate}}
                @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
                @questions={{model.clusterTemplateRevision.questions}}
                @value={{maxUnavailable}}
              >
                {{#input-or-display
                    editable=notView
                    value=maxUnavailable
                }}
                  <div class="input-group">
                    {{input-integer
                      value=upgradeStrategy.maxUnavailableWorker
                      classNames="form-control"
                      placeholder=(t "clusterNew.rke.upgradeStrategy.maximumWorkersDown.placeholder")
                    }}
                    <span class="input-group-input-addon bg-default">
                      {{new-select
                        classNames="form-control"
                        optionValuePath="id"
                        optionLabelPath="name"
                        content=maxUnavailableNodesOptions
                        value=upgradeStrategy.maxUnavailableUnit
                        localizedPrompt=true
                      }}
                    </span>
                  </div>
                {{/input-or-display}}
              </CheckOverrideAllowed>
            </div>

          </div>
          <div class="row">
            <label class="acc-label">
              {{t "clusterNew.rke.upgradeStrategy.drainNodes.label"}}
              {{#if clusterTemplateCreate}}
                <ClusterTemplateOverrideToggle
                  @path="rancherKubernetesEngineConfig.upgradeStrategy.drain"
                  @configVariable={{upgradeStrategy.drain}}
                  @addOverride={{action "addOverride"}}
                  @questions={{model.clusterTemplateRevision.questions}}
                />
              {{/if}}
            </label>
            <CheckOverrideAllowed
              @paramName="rancherKubernetesEngineConfig.upgradeStrategy.drain"
              @applyClusterTemplate={{applyClusterTemplate}}
              @clusterTemplateRevision={{model.clusterTemplateRevision.clusterConfig}}
              @questions={{model.clusterTemplateRevision.questions}}
              @value={{upgradeStrategy.drain}}
            >
              {{#input-or-display
                  editable=notView
                  value=upgradeStrategy.drain
              }}
                <div class="text-muted">
                  <label>
                    {{radio-button
                      selection=upgradeStrategy.drain
                      value="true"
                    }}
                    {{t "generic.yes"}}

                  </label>
                  <label>
                    {{radio-button
                      selection=upgradeStrategy.drain
                      value="false"
                    }}
                    {{t "generic.no"}}
                  </label>
                </div>
              {{/input-or-display}}
            </CheckOverrideAllowed>
          </div>
          {{#if (eq upgradeStrategy.drain "true")}}
            <div class="row">
              {{drain-node selection=upgradeStrategy.nodeDrainInput clusterTemplateCreate=clusterTemplateCreate editable=notView applyClusterTemplate=applyClusterTemplate clusterTemplateRevision=model.clusterTemplateRevision.clusterConfig questions=model.clusterTemplateRevision.questions addOverride=(action "addOverride")}}
            </div>
          {{/if}}
          {{#unless clusterTemplateCreate}}
            <div class="row mt-10">
              <label class="acc-label">
                {{t "clusterNew.rke.agentEnvVars.label"}}
              </label>
              <FormAgentEnvVar
                @editable={{notView}}
                @value={{mut agentEnvVars}}
              />
            </div>
          {{/unless}}
        {{/accordion-list-item}}

        {{#accordion-list-item
           title=(t "clusterNew.rke.authorizedEndpoint.title")
           detail=(t "clusterNew.rke.authorizedEndpoint.detail")
           expandOnInit=(or (or (eq mode "edit" true false) forceExpandOnInit) applyClusterTemplate)
           expandAll=al.expandAll
           expand=(action expandFn)
        }}
          <AuthorizedEndpoint
            @mode={{mode}}
            @addOverride={{action "addOverride"}}
            @cluster={{cluster}}
            @clusterTemplateCreate={{clusterTemplateCreate}}
            @clusterTemplateRevision={{model.clusterTemplateRevision}}
            @applyClusterTemplate={{applyClusterTemplate}}
          />
        {{/accordion-list-item}}

      {{/if}}
    {{/accordion-list}}
  {{/if}} {{!-- endif (or isEdit (eq step 1)) --}}


  {{#if (and isCustom (eq step 2)) }}
    {{#accordion-list
       expandAll=(mut forceExpandAll)
       showExpandAll=false
       as |al expandFn|
    }}
      {{#if isWindowsPreferedCluster}}
        {{#accordion-list-item
           title=(t "clusterNew.rke.system.title")
           detail=(t "clusterNew.rke.system.detail")
           expandOnInit=true
           expandAll=al.expandAll
           expand=(action expandFn)
        }}
          <div class="row">
            <div class="col span-6 text-center mt-0 mb-0">
              <div class="radio">
                <label>
                  {{radio-button selection=isLinux value=true}}
                  {{t "clusterNew.rke.system.linux"}}
                </label>
              </div>
            </div>
            <div class="col span-6 text-center mt-0 mb-0">
              <div class="radio">
                <label>
                  {{radio-button selection=isLinux value=false}}
                  {{t "clusterNew.rke.system.windows"}}
                </label>
              </div>
            </div>
          </div>
        {{/accordion-list-item}}
      {{/if}}
      {{#accordion-list-item
         title=(t "clusterNew.rke.role.pageheader")
         detail=(t "clusterNew.rke.info.text")
         expandOnInit=true
         expandAll=al.expandAll
         expand=(action expandFn)
      }}
        <CustomCommand @token={{token}} @isLinux={{isLinux}}/>
      {{/accordion-list-item}}
    {{/accordion-list}}

    {{#if newNodeCount}}
      <BannerMessage
        @color="bg-success"
        @message={{t "clusterNew.rke.detected" count=newNodeCount}}
      />
    {{/if}}
  {{/if}} {{!-- endif (and isCustom (eq step 2)) --}}

  {{#if clusterTemplateCreate}}
    {{#if (or isEdit (eq step 1))}}
      {{#accordion-list
         expandAll=(mut forceExpandAll)
         showExpandAll=false
         as |al expandFn|
      }}
        {{#accordion-list-item
           title=(t "clusterTemplateQuestions.label")
           detail=(t "clusterTemplateQuestions.detail")
           expandAll=al.expandAll
           expand=(action expandFn)
           expandOnInit=true
        }}
          <CruClusterTemplateQuestions
            @addQuestion={{addQuestion}}
            @removeQuestion={{removeQuestion}}
            @allQuestions={{clusterTemplateQuestions}}
            @applyClusterTemplate={{applyClusterTemplate}}
            @clusterTemplateCreate={{clusterTemplateCreate}}
          />
        {{/accordion-list-item}}
      {{/accordion-list}}
    {{/if}}
  {{/if}}
{{/if}}

{{top-errors errors=allErrors}}

{{#if (or (and notView (eq step 1)) (and (and (not isPostSave) isEdit) (eq step 2)))}}
  {{#if (and clusterTemplatesEnforced (not clusterTemplateRevisionId) )}}
    <section class="mt-20 mb-20">
      <BannerMessage
        @color="bg-warning m-0"
        @message={{t "clusterNew.rke.clusterTempalteMissing"}}
      />
    </section>
    <div class="footer-actions">
      <button class="btn bg-primary" type="button" {{action "close"}}>
        {{t "generic.cancel"}}
      </button>
    </div>
  {{else}}
    {{save-cancel
      createLabel=(or overrideCreateLabel (if isCustom "saveCancel.next" "saveCancel.create"))
      editing=isEdit
      save=(action "driverSave")
      cancel=(action "close")
    }}
  {{/if}}
{{else}}
  <div class="footer-actions">
    <button class="btn bg-primary" type="button" {{action "close"}}>
      {{t "clusterNew.rke.done"}}
    </button>
  </div>
{{/if}}

<input
  type="file"
  accept="{{actualAccept}}"
  class="hide"
>
